import { Pipe, PipeTransform } from '@angular/core';

@Pipe({
  name: 'dealObj'
})

export class DealObjPipe implements PipeTransform {
  transform(value: any, rtn: string): any {
    if(rtn === 'value'){
      return Object.values(value)
    }
    if(rtn === 'key'){
      return Object.keys(value)
    }
    return value
  }
}